home *** CD-ROM | disk | FTP | other *** search
/ Amiga Plus 2000 #1 / Amiga Plus CD - 2000 - No. 1.iso / Tools / Dev / Meshwriter_lib / Library / include / meshwriter / meshwriter.h next >
Encoding:
C/C++ Source or Header  |  1999-12-03  |  4.3 KB  |  116 lines

  1. /*
  2. **      $VER: meshwriter.h 0.2 (28.3.99)
  3. **
  4. **      main include file for meshwriter.library
  5. **
  6. **      Stephan Bielmann
  7. */
  8.  
  9. #ifndef MESHWRITER_MESHWRITER_H
  10. #define MESHWRITER_MESHWRITER_H
  11.  
  12. /**************************** Includes ******************************/
  13.  
  14. #include <exec/types.h>
  15.  
  16. /**************************** Defines *******************************/
  17.  
  18. /*
  19. ** 3D file types
  20. */
  21. #define  T3DFRAWA   1     /* RAW ASCII            raw    */
  22. #define  T3DFRAWB   2     /* RAW binary           raw    */
  23. #define  T3DFDXF    3     /* AutoCAD DXF          dxf    */
  24. #define  T3DFVRML1  4     /* VRML 1               wrl    */
  25. #define  T3DFPOV3   5     /* POVRay 3.X           pov    */
  26. #define  T3DFLWOB   6     /* Lightwave            lwob   */
  27. #define  T3DFTDDD   7     /* Imagine original     iob    */
  28. #define  T3DFTDDDH  8     /* Imagine huge         iob    */
  29. #define  T3DFREF4   9     /* Reflections 4.X      r4     */
  30. #define  T3DFGEOA   10    /* Videoscape ASCII     geo    */
  31. #define  T3DFREAL   11    /* Real 3D              real   */
  32.  
  33. /*
  34. ** 2D file types
  35. */
  36. #define  T2DFEPS    1     /* Encapsulated PostScript   eps   */
  37. #define  T2DFPSP    2     /* PostScript portrait       ps    */
  38. #define  T2DFPSL    3     /* PostScript landscape      ps    */
  39.  
  40. /*
  41. ** View types
  42. */
  43. #define TVWTOP     1 /* Top view, xy axis               */
  44. #define TVWBOTTOM  2 /* Bottom view, xy axis            */
  45. #define TVWLEFT    3 /* Left view yz axis               */
  46. #define TVWRIGHT   4 /* Right view yz axis              */
  47. #define TVWFRONT   5 /* Front view xz axis              */
  48. #define TVWBACK    6 /* Back view xz axis               */
  49. #define TVWPERSP   7 /* Perspectiv view                 */
  50. #define TVW4SIDES  8 /* Top, front, left and perspecive */
  51.  
  52. /*
  53. ** drawing modes
  54. */
  55. #define TDMPOINTS  1 /* Points, black and white    */
  56. #define TDMGRIDBW  2 /* Grid, black and white      */
  57. #define TDMGRIDGR  3 /* Grid, gray scales          */
  58. #define TDMGRIDCL  4 /* Grid, colors               */
  59. #define TDMSURFBW  5 /* Surface, black and white   */
  60. #define TDMSURFGR  6 /* Surface, gray scales       */
  61. #define TDMSURFCL  7 /* Surface, colors            */
  62.  
  63. /*
  64. ** Return codes, IoErr will be used too to get AmigaDos errors
  65. */
  66. #define RCNOERROR                     0      /* All went well.                           */
  67. #define RCNOMEMORY                    2000   /* No more free memory.                     */
  68. #define RCNOMESH                      2001   /* No mesh to process.                      */
  69. #define RCNOPOLYGON                   2002   /* No polygon  to process.                  */
  70. #define RCNOMATERIAL                  2003   /* No material to process.                  */
  71. #define RCUNKNOWNFTYPE                2004   /* Unkown file type.                        */
  72. #define RCUNKNOWNVTYPE                2005   /* Unkown view type.                        */
  73. #define RCUNKNOWNDMODE                2006   /* Unkown draw mode.                        */
  74. #define RCCHGBUF                      2007   /* Could not change the buffer size.        */
  75. #define RCWRITEDATA                   2008   /* Error occured while writing the file.    */
  76. #define RCVERTEXOVERFLOW              2009   /* Error, too much vertices.                */
  77. #define RCVALUEOUTOFRANGE             2010   /* An argument its value is out of range.   */
  78. #define RCVERTEXINPOLYGONOVERFLOW     2011   /* Error, too much vertices in a polygon.   */
  79. #define RCNOVERTEX                    2012   /* The vertex is not in the mesh.           */
  80. #define RCVERTEXUNDERFLOW             2013   /* Error, not enough vertices.              */
  81. #define RCINVALIDOPERATION            2014   /* The operation you want to do is invalid. */
  82.  
  83. /*
  84. ** CTM operations
  85. */
  86. #define CTMADD   1 /* Add the value to the CTM       */
  87. #define CTMSUB   2 /* Substract the value to the CTM */
  88. #define CTMMUL   3 /* Multiply the value to the CTM  */
  89. #define CTMDIV   4 /* Divide the value to the CTM    */
  90. #define CTMSET   5 /* Set the value in the CTM       */
  91. #define CTMRESET 6 /* Reset the value in the CTM     */
  92.  
  93. /*********************** Type definitions ***************************/
  94.  
  95. /*
  96. ** Primitive types
  97. */
  98. typedef FLOAT TOCLFloat;
  99.  
  100. /*
  101. ** Vertex structure
  102. */
  103. typedef struct {
  104.   TOCLFloat x,y,z;
  105. }TOCLVertex;
  106.  
  107. /*
  108. ** Color structure
  109. */
  110. typedef struct {
  111.   UBYTE r,g,b;
  112. }TOCLColor;
  113.  
  114. #endif /* MESHWRITER_MESHWRITER_H */
  115. /************************* End of file ******************************/
  116.